Integrand size = 21, antiderivative size = 78 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=-\frac {b d^2 n}{x}-b e^2 n x-b d e n \log ^2(x)-\frac {d^2 \left (a+b \log \left (c x^n\right )\right )}{x}+e^2 x \left (a+b \log \left (c x^n\right )\right )+2 d e \log (x) \left (a+b \log \left (c x^n\right )\right ) \]
-b*d^2*n/x-b*e^2*n*x-b*d*e*n*ln(x)^2-d^2*(a+b*ln(c*x^n))/x+e^2*x*(a+b*ln(c *x^n))+2*d*e*ln(x)*(a+b*ln(c*x^n))
Time = 0.04 (sec) , antiderivative size = 76, normalized size of antiderivative = 0.97 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=-\frac {b d^2 n}{x}+a e^2 x-b e^2 n x+b e^2 x \log \left (c x^n\right )-\frac {d^2 \left (a+b \log \left (c x^n\right )\right )}{x}+\frac {d e \left (a+b \log \left (c x^n\right )\right )^2}{b n} \]
-((b*d^2*n)/x) + a*e^2*x - b*e^2*n*x + b*e^2*x*Log[c*x^n] - (d^2*(a + b*Lo g[c*x^n]))/x + (d*e*(a + b*Log[c*x^n])^2)/(b*n)
Time = 0.27 (sec) , antiderivative size = 74, normalized size of antiderivative = 0.95, number of steps used = 2, number of rules used = 2, \(\frac {\text {number of rules}}{\text {integrand size}}\) = 0.095, Rules used = {2772, 2009}
Below are the steps used by Rubi to obtain the solution. The rule number used for the transformation is given above next to the arrow. The rules definitions used are listed below.
\(\displaystyle \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx\) |
\(\Big \downarrow \) 2772 |
\(\displaystyle -b n \int \left (-\frac {d^2}{x^2}+\frac {2 e \log (x) d}{x}+e^2\right )dx-\frac {d^2 \left (a+b \log \left (c x^n\right )\right )}{x}+2 d e \log (x) \left (a+b \log \left (c x^n\right )\right )+e^2 x \left (a+b \log \left (c x^n\right )\right )\) |
\(\Big \downarrow \) 2009 |
\(\displaystyle -\frac {d^2 \left (a+b \log \left (c x^n\right )\right )}{x}+2 d e \log (x) \left (a+b \log \left (c x^n\right )\right )+e^2 x \left (a+b \log \left (c x^n\right )\right )-b n \left (\frac {d^2}{x}+d e \log ^2(x)+e^2 x\right )\) |
-(b*n*(d^2/x + e^2*x + d*e*Log[x]^2)) - (d^2*(a + b*Log[c*x^n]))/x + e^2*x *(a + b*Log[c*x^n]) + 2*d*e*Log[x]*(a + b*Log[c*x^n])
3.1.14.3.1 Defintions of rubi rules used
Int[((a_.) + Log[(c_.)*(x_)^(n_.)]*(b_.))*(x_)^(m_.)*((d_) + (e_.)*(x_)^(r_ .))^(q_.), x_Symbol] :> With[{u = IntHide[x^m*(d + e*x^r)^q, x]}, Simp[(a + b*Log[c*x^n]) u, x] - Simp[b*n Int[SimplifyIntegrand[u/x, x], x], x]] /; FreeQ[{a, b, c, d, e, n, r}, x] && IGtQ[q, 0] && IntegerQ[m] && !(EqQ[q , 1] && EqQ[m, -1])
Time = 0.45 (sec) , antiderivative size = 96, normalized size of antiderivative = 1.23
method | result | size |
parallelrisch | \(\frac {x^{2} \ln \left (c \,x^{n}\right ) b \,e^{2} n -x^{2} b \,e^{2} n^{2}+2 \ln \left (x \right ) x a d e n +x^{2} a \,e^{2} n +b d e \ln \left (c \,x^{n}\right )^{2} x -\ln \left (c \,x^{n}\right ) b \,d^{2} n -b \,d^{2} n^{2}-a \,d^{2} n}{x n}\) | \(96\) |
risch | \(-\frac {b \left (-2 d e x \ln \left (x \right )-e^{2} x^{2}+d^{2}\right ) \ln \left (x^{n}\right )}{x}-\frac {-2 i \ln \left (x \right ) \pi b d e \,\operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2} x +i \pi b \,d^{2} \operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}+i \pi b \,e^{2} x^{2} \operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )+i \pi b \,d^{2} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}-i \pi b \,e^{2} x^{2} \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}-i \pi b \,e^{2} x^{2} \operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2}-i \pi b \,d^{2} \operatorname {csgn}\left (i c \,x^{n}\right )^{3}-i \pi b \,d^{2} \operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right )+2 i \ln \left (x \right ) \pi b d e \operatorname {csgn}\left (i c \,x^{n}\right )^{3} x +i \pi b \,e^{2} x^{2} \operatorname {csgn}\left (i c \,x^{n}\right )^{3}-2 i \ln \left (x \right ) \pi b d e \,\operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i c \,x^{n}\right )^{2} x +2 i \ln \left (x \right ) \pi b d e \,\operatorname {csgn}\left (i c \right ) \operatorname {csgn}\left (i x^{n}\right ) \operatorname {csgn}\left (i c \,x^{n}\right ) x +2 b d e n \ln \left (x \right )^{2} x -4 \ln \left (x \right ) \ln \left (c \right ) b d e x -2 \ln \left (c \right ) b \,e^{2} x^{2}+2 b \,e^{2} n \,x^{2}-4 \ln \left (x \right ) a d e x -2 a \,e^{2} x^{2}+2 d^{2} b \ln \left (c \right )+2 b \,d^{2} n +2 a \,d^{2}}{2 x}\) | \(419\) |
1/x*(x^2*ln(c*x^n)*b*e^2*n-x^2*b*e^2*n^2+2*ln(x)*x*a*d*e*n+x^2*a*e^2*n+b*d *e*ln(c*x^n)^2*x-ln(c*x^n)*b*d^2*n-b*d^2*n^2-a*d^2*n)/n
Time = 0.30 (sec) , antiderivative size = 98, normalized size of antiderivative = 1.26 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=\frac {b d e n x \log \left (x\right )^{2} - b d^{2} n - a d^{2} - {\left (b e^{2} n - a e^{2}\right )} x^{2} + {\left (b e^{2} x^{2} - b d^{2}\right )} \log \left (c\right ) + {\left (b e^{2} n x^{2} + 2 \, b d e x \log \left (c\right ) - b d^{2} n + 2 \, a d e x\right )} \log \left (x\right )}{x} \]
(b*d*e*n*x*log(x)^2 - b*d^2*n - a*d^2 - (b*e^2*n - a*e^2)*x^2 + (b*e^2*x^2 - b*d^2)*log(c) + (b*e^2*n*x^2 + 2*b*d*e*x*log(c) - b*d^2*n + 2*a*d*e*x)* log(x))/x
Time = 0.33 (sec) , antiderivative size = 112, normalized size of antiderivative = 1.44 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=\begin {cases} - \frac {a d^{2}}{x} + \frac {2 a d e \log {\left (c x^{n} \right )}}{n} + a e^{2} x - \frac {b d^{2} n}{x} - \frac {b d^{2} \log {\left (c x^{n} \right )}}{x} + \frac {b d e \log {\left (c x^{n} \right )}^{2}}{n} - b e^{2} n x + b e^{2} x \log {\left (c x^{n} \right )} & \text {for}\: n \neq 0 \\\left (a + b \log {\left (c \right )}\right ) \left (- \frac {d^{2}}{x} + 2 d e \log {\left (x \right )} + e^{2} x\right ) & \text {otherwise} \end {cases} \]
Piecewise((-a*d**2/x + 2*a*d*e*log(c*x**n)/n + a*e**2*x - b*d**2*n/x - b*d **2*log(c*x**n)/x + b*d*e*log(c*x**n)**2/n - b*e**2*n*x + b*e**2*x*log(c*x **n), Ne(n, 0)), ((a + b*log(c))*(-d**2/x + 2*d*e*log(x) + e**2*x), True))
Time = 0.19 (sec) , antiderivative size = 83, normalized size of antiderivative = 1.06 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=-b e^{2} n x + b e^{2} x \log \left (c x^{n}\right ) + a e^{2} x + \frac {b d e \log \left (c x^{n}\right )^{2}}{n} + 2 \, a d e \log \left (x\right ) - \frac {b d^{2} n}{x} - \frac {b d^{2} \log \left (c x^{n}\right )}{x} - \frac {a d^{2}}{x} \]
-b*e^2*n*x + b*e^2*x*log(c*x^n) + a*e^2*x + b*d*e*log(c*x^n)^2/n + 2*a*d*e *log(x) - b*d^2*n/x - b*d^2*log(c*x^n)/x - a*d^2/x
Time = 0.37 (sec) , antiderivative size = 93, normalized size of antiderivative = 1.19 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=b d e n \log \left (x\right )^{2} + {\left (x \log \left (x\right ) - x\right )} b e^{2} n - b d^{2} n {\left (\frac {\log \left (x\right )}{x} + \frac {1}{x}\right )} + b e^{2} x \log \left (c\right ) + 2 \, b d e \log \left (c\right ) \log \left ({\left | x \right |}\right ) + a e^{2} x + 2 \, a d e \log \left ({\left | x \right |}\right ) - \frac {b d^{2} \log \left (c\right )}{x} - \frac {a d^{2}}{x} \]
b*d*e*n*log(x)^2 + (x*log(x) - x)*b*e^2*n - b*d^2*n*(log(x)/x + 1/x) + b*e ^2*x*log(c) + 2*b*d*e*log(c)*log(abs(x)) + a*e^2*x + 2*a*d*e*log(abs(x)) - b*d^2*log(c)/x - a*d^2/x
Time = 0.35 (sec) , antiderivative size = 99, normalized size of antiderivative = 1.27 \[ \int \frac {(d+e x)^2 \left (a+b \log \left (c x^n\right )\right )}{x^2} \, dx=\ln \left (x\right )\,\left (2\,a\,d\,e+2\,b\,d\,e\,n\right )-\frac {a\,d^2+b\,d^2\,n}{x}-\ln \left (c\,x^n\right )\,\left (\frac {b\,d^2+2\,b\,d\,e\,x+b\,e^2\,x^2}{x}-2\,b\,e^2\,x\right )+e^2\,x\,\left (a-b\,n\right )+\frac {b\,d\,e\,{\ln \left (c\,x^n\right )}^2}{n} \]